<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.13"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>SC2API: include/sc2api/sc2_score.h File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="SC2-Logo.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">SC2API
   </div>
   <div id="projectbrief">An API for AI for StarCraft II</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.13 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_d44c64559bbebec7f509842c48db8b23.html">include</a></li><li class="navelem"><a class="el" href="dir_3d0dfd3160b31ffa512c49330ac8d646.html">sc2api</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#nested-classes">Classes</a> &#124;
<a href="#define-members">Macros</a> &#124;
<a href="#enum-members">Enumerations</a>  </div>
  <div class="headertitle">
<div class="title">sc2_score.h File Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>Scores accumulated in a game as calculated by the game engine.  
<a href="#details">More...</a></p>
<div class="textblock"><code>#include &quot;sc2_proto_interface.h&quot;</code><br />
<code>#include &quot;<a class="el" href="sc2__gametypes_8h_source.html">sc2_gametypes.h</a>&quot;</code><br />
<code>#include &lt;vector&gt;</code><br />
<code>#include &lt;string&gt;</code><br />
<code>#include &lt;stdint.h&gt;</code><br />
</div>
<p><a href="sc2__score_8h_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a>
Classes</h2></td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structsc2_1_1_score_entry.html">sc2::ScoreEntry</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structsc2_1_1_category_score_details.html">sc2::CategoryScoreDetails</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight"><a class="el" href="structsc2_1_1_score.html" title="Scores. ">Score</a> by category.  <a href="structsc2_1_1_category_score_details.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structsc2_1_1_vital_score_details.html">sc2::VitalScoreDetails</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight"><a class="el" href="structsc2_1_1_score.html" title="Scores. ">Score</a> for vitals.  <a href="structsc2_1_1_vital_score_details.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structsc2_1_1_score_details.html">sc2::ScoreDetails</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Detailed scores.  <a href="structsc2_1_1_score_details.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structsc2_1_1_score.html">sc2::Score</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Scores.  <a href="structsc2_1_1_score.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a>
Macros</h2></td></tr>
<tr class="memitem:a6709f7681d50d9695b8011b5f1b5cb80"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><b>SET_ENTRY_BASE</b>(STRUCTNAME,  ENTRYNAME)</td></tr>
<tr class="separator:a6709f7681d50d9695b8011b5f1b5cb80"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9608bb575077483d8b5c84fdc622893f"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><b>SET_ENTRY_BASE_STRUCT</b>(STRUCTNAME,  ENTRYNAME)</td></tr>
<tr class="separator:a9608bb575077483d8b5c84fdc622893f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:acdf45bc582fc437e9d62011af4b47ba0"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><b>SET_ENTRY</b>(STRUCTNAME,  ENTRYNAME)</td></tr>
<tr class="separator:acdf45bc582fc437e9d62011af4b47ba0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1bd7e9783b9cf7e1ce6efd3cf55575a0"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><b>SET_ENTRY_STRUCT</b>(STRUCTNAME,  ENTRYNAME)</td></tr>
<tr class="separator:a1bd7e9783b9cf7e1ce6efd3cf55575a0"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="enum-members"></a>
Enumerations</h2></td></tr>
<tr class="memitem:aa4e8dbe2d274f393f7afb290ba84657a"><td class="memItemLeft" align="right" valign="top"><a id="aa4e8dbe2d274f393f7afb290ba84657a"></a>enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="sc2__score_8h.html#aa4e8dbe2d274f393f7afb290ba84657a">sc2::ScoreType</a> { <b>sc2::ScoreType::Curriculum</b> = 1, 
<b>sc2::ScoreType::Melee</b> = 2
 }<tr class="memdesc:aa4e8dbe2d274f393f7afb290ba84657a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Source of a score. <br /></td></tr>
</td></tr>
<tr class="separator:aa4e8dbe2d274f393f7afb290ba84657a"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Scores accumulated in a game as calculated by the game engine. </p>
</div><h2 class="groupheader">Macro Definition Documentation</h2>
<a id="acdf45bc582fc437e9d62011af4b47ba0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#acdf45bc582fc437e9d62011af4b47ba0">&#9670;&nbsp;</a></span>SET_ENTRY</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define SET_ENTRY</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">STRUCTNAME, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">ENTRYNAME&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<b>Value:</b><div class="fragment"><div class="line">{                                                                               \</div><div class="line">        ScoreEntry new_entry = base;                                                \</div><div class="line">        new_entry.offset += (int)int64_t(&amp;(((STRUCTNAME*)0)-&gt;ENTRYNAME));           \</div><div class="line">        new_entry.name += <span class="stringliteral">&quot;.&quot;</span>#ENTRYNAME;                                            \</div><div class="line">        entries.push_back(new_entry);                                               \</div><div class="line">    }</div></div><!-- fragment -->
</div>
</div>
<a id="a6709f7681d50d9695b8011b5f1b5cb80"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a6709f7681d50d9695b8011b5f1b5cb80">&#9670;&nbsp;</a></span>SET_ENTRY_BASE</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define SET_ENTRY_BASE</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">STRUCTNAME, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">ENTRYNAME&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<b>Value:</b><div class="fragment"><div class="line">{                                                                               \</div><div class="line">        ScoreEntry new_entry;                                                       \</div><div class="line">        new_entry.offset += (int)int64_t(&amp;(((STRUCTNAME*)0)-&gt;ENTRYNAME));           \</div><div class="line">        new_entry.name += #STRUCTNAME<span class="stringliteral">&quot;.&quot;</span>#ENTRYNAME;                                 \</div><div class="line">        entries.push_back(new_entry);                                               \</div><div class="line">    }</div></div><!-- fragment -->
</div>
</div>
<a id="a9608bb575077483d8b5c84fdc622893f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9608bb575077483d8b5c84fdc622893f">&#9670;&nbsp;</a></span>SET_ENTRY_BASE_STRUCT</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define SET_ENTRY_BASE_STRUCT</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">STRUCTNAME, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">ENTRYNAME&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<b>Value:</b><div class="fragment"><div class="line">{                                                                               \</div><div class="line">        ScoreEntry base_entry;                                                      \</div><div class="line">        base_entry.offset += (int)int64_t(&amp;(((STRUCTNAME*)0)-&gt;ENTRYNAME));          \</div><div class="line">        base_entry.name += #STRUCTNAME<span class="stringliteral">&quot;.&quot;</span>#ENTRYNAME;                                \</div><div class="line">        ((STRUCTNAME*)0)-&gt;ENTRYNAME.AddEntries(base_entry, entries);                \</div><div class="line">    }</div></div><!-- fragment -->
</div>
</div>
<a id="a1bd7e9783b9cf7e1ce6efd3cf55575a0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1bd7e9783b9cf7e1ce6efd3cf55575a0">&#9670;&nbsp;</a></span>SET_ENTRY_STRUCT</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define SET_ENTRY_STRUCT</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">STRUCTNAME, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">ENTRYNAME&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<b>Value:</b><div class="fragment"><div class="line">{                                                                               \</div><div class="line">        ScoreEntry new_entry = base;                                                \</div><div class="line">        new_entry.offset += (int)int64_t(&amp;(((STRUCTNAME*)0)-&gt;ENTRYNAME));           \</div><div class="line">        new_entry.name += <span class="stringliteral">&quot;.&quot;</span>#ENTRYNAME;                                            \</div><div class="line">        ((STRUCTNAME*)0)-&gt;ENTRYNAME.AddEntries(new_entry, entries);                 \</div><div class="line">    }</div></div><!-- fragment -->
</div>
</div>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.13
</small></address>
</body>
</html>
